package hottargui.config;

import hottargui.framework.*;

public class AlphaEndTurnState implements TarguiState {

	Game gameContext;
	
	public AlphaEndTurnState(Game game)
	{
		this.gameContext = game;
	}
	
	@Override
	public boolean buy(int count, Position deploy) throws IllegalActionException {
		throw new IllegalActionException(this.getState());
	}

	@Override
	public State getState() {
		return State.endTurn;
	}

	@Override
	public boolean move(Position from, Position to, int count)
			throws IllegalActionException {
		throw new IllegalActionException(this.getState());
	}

	@Override
	public void newGame() throws IllegalActionException {
		throw new IllegalActionException(this.getState());
	}

	@Override
	public void rollDie() throws IllegalActionException {
		throw new IllegalActionException(this.getState());
	}

	@Override
	public PlayerColor turnCard() throws IllegalActionException {
		// TODO: Replace this stub
		// TODO: Implement turncontrol
		
		gameContext.setState(gameContext.getFactory().getMoveState(gameContext));
		
		return PlayerColor.None;
	}

	@Override
	public PlayerColor getWinner() throws IllegalActionException {
		throw new IllegalActionException(this.getState());
	}

}
